package com.marktotop.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.marktotop.entity.system.Department;
import com.marktotop.error.SystemException;
import com.marktotop.response.ResultBean;
import com.marktotop.vo.system.DeanVO;
import com.marktotop.vo.system.DepartmentVO;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author MarkToTop
 * @since 2021-07-12
 */
public interface IDepartmentService extends IService<Department> {

    /**
     * 根据 部门id 查询 部门信息
     *
     * @param departmentId
     * @return
     * @throws SystemException
     */
    DepartmentVO editDept(Long departmentId) throws SystemException;


    /**
     * 分页展示部门列表
     *
     * @param pageNum
     * @param pageSize
     * @param departmentVO
     * @return
     */
    ResultBean findDepartmentList(Integer pageNum, Integer pageSize, DepartmentVO departmentVO);


    /**
     * 查询所有部门
     *
     * @return
     */
    List<DepartmentVO> findAllVO();


    /**
     * 查找部门主任
     *
     * @return
     */
    List<DeanVO> findDeanList();

    /**
     * 添加新的部门信息
     *
     * @param departmentVO
     */
    void addDept(DepartmentVO departmentVO);

    /**
     * 更新部门信息
     *
     * @param id
     * @param departmentVO
     */
    void updateDept(Long id, DepartmentVO departmentVO) throws SystemException;
}
